package com.fuluwa.domain.knowledge.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import org.apache.commons.lang3.builder.ToStringBuilder;

@Entity
@Table(name = "t_knowledge_file")
public class File extends Knowledge {

	@Column(length = 256, nullable = false)
	private String name; // 文档名称

	@Column(length = 256)
	private String alias; // 文档别名

	@Column(nullable = false)
	private short type; // 文档类型，doc\ppt\excel\txt等

	@Column(length = 512, nullable = false)
	private String storeAddr; // 存数地址，URL

	@Column(length = 512)
	private String transAddr; // 转存地址，URL

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getAlias() {
		return alias;
	}

	public void setAlias(String alias) {
		this.alias = alias;
	}

	public short getType() {
		return type;
	}

	public void setType(short type) {
		this.type = type;
	}

	public String getStoreAddr() {
		return storeAddr;
	}

	public void setStoreAddr(String storeAddr) {
		this.storeAddr = storeAddr;
	}

	public String getTransAddr() {
		return transAddr;
	}

	public void setTransAddr(String transAddr) {
		this.transAddr = transAddr;
	}
	
	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}

}
